package a.i;

import a.c.i;
import a.c.j;
import a.c.k;
import a.c.n;
import a.c.q;
import a.c.x;

public class sb
  implements k
{
  private k a;
  private Object b;
  private q c;
  private k d;
  private j e;
  public static boolean f;
  
  public sb(k paramk1, k paramk2)
  {
    this.a = paramk2;
    this.d = paramk1;
    a(paramk1);
  }
  
  public sb(k paramk, q paramq, Object paramObject)
  {
    this.d = paramk;
    c(paramq, paramObject);
    a(paramk);
  }
  
  public j a()
  {
    if (!p.b) {
      if (this.e == null) {
        throw new IllegalStateException("wrapper must be of type DataAcceptor");
      }
    }
    return this.e;
  }
  
  private void a(k paramk)
  {
    if ((paramk instanceof i)) {
      this.e = new j()
      {
        public Object get(Object paramAnonymousObject)
        {
          boolean bool = p.b;
          k localk = sb.this.a;
          if (!bool) {
            if (localk != null)
            {
              Object localObject = localk.get(paramAnonymousObject);
              if (bool) {
                break label54;
              }
              if (localObject != null) {
                return localObject;
              }
            }
          }
          label54:
          return sb.this.d.get(paramAnonymousObject);
        }
        
        public int getInt(Object paramAnonymousObject)
        {
          throw new IllegalStateException("Only get(Object) may be used");
        }
        
        public double getDouble(Object paramAnonymousObject)
        {
          throw new IllegalStateException("Only get(Object) may be used");
        }
        
        public boolean getBool(Object paramAnonymousObject)
        {
          throw new IllegalStateException("Only get(Object) may be used");
        }
        
        public void a(Object paramAnonymousObject1, Object paramAnonymousObject2)
        {
          ((i)sb.this.d).a(paramAnonymousObject1, paramAnonymousObject2);
        }
        
        public void a(Object paramAnonymousObject, int paramAnonymousInt)
        {
          throw new IllegalStateException("Only set(Object) may be used");
        }
        
        public void a(Object paramAnonymousObject, double paramAnonymousDouble)
        {
          throw new IllegalStateException("Only set(Object) may be used");
        }
        
        public void a(Object paramAnonymousObject, boolean paramAnonymousBoolean)
        {
          throw new IllegalStateException("Only set(Object) may be used");
        }
      };
    }
  }
  
  public static sb a(q paramq, Object paramObject)
  {
    return new sb(paramq.C(), paramq, paramObject);
  }
  
  public static sb b(q paramq, Object paramObject)
  {
    return new sb(paramq.B(), paramq, paramObject);
  }
  
  public void c(q paramq, Object paramObject)
  {
    boolean bool = p.b;
    if (paramObject == null) {
      throw new IllegalArgumentException("Key must be non-null!");
    }
    this.a = paramq.c(paramObject);
    this.b = paramObject;
    this.c = paramq;
    if (!bool)
    {
      if (this.a != null)
      {
        paramq.j(paramObject);
        if (bool) {
          break label75;
        }
        paramq.a(paramObject, this);
      }
    }
    else if (!p.a) {
      return;
    }
    label75:
    paramq.a(paramObject, this.d);
  }
  
  public void b()
  {
    boolean bool = p.b;
    if (!bool) {
      if (this.b == null) {
        throw new IllegalStateException("Provider must have been wrapped previously!");
      }
    }
    k localk = this.c.c(this.b);
    if (!bool) {
      if (localk != null) {
        this.c.j(this.b);
      }
    }
    if ((bool) || (this.a != null)) {
      this.c.a(this.b, this.a);
    }
  }
  
  public Object get(Object paramObject)
  {
    boolean bool = p.b;
    Object localObject = this.d.get(paramObject);
    if ((bool) || (localObject != null)) {
      return localObject;
    }
    if ((bool) || (this.a != null)) {
      return this.a.get(paramObject);
    }
    return null;
  }
  
  public boolean getBool(Object paramObject)
  {
    throw new UnsupportedOperationException("Object supported only!");
  }
  
  public double getDouble(Object paramObject)
  {
    throw new UnsupportedOperationException("Object supported only!");
  }
  
  public int getInt(Object paramObject)
  {
    throw new UnsupportedOperationException("Object supported only!");
  }
  
  public k c()
  {
    return this.a;
  }
  
  public k d()
  {
    return this.d;
  }
  
  public void e()
  {
    boolean bool = p.b;
    b();
    if (!bool)
    {
      if ((this.d instanceof x)) {
        this.c.a((x)this.d);
      }
      if (bool) {}
    }
    else
    {
      if ((this.d instanceof n)) {
        this.c.a((n)this.d);
      }
      this.d = null;
      this.a = null;
    }
    this.c = null;
  }
}


/* Location:           E:\idea\
 * Qualified Name:     a.i.sb
 * JD-Core Version:    0.7.0.1
 */